package com.shop.loan.model.vo;

import lombok.Getter;
import lombok.Setter;
import xyz.erupt.annotation.Erupt;
import xyz.erupt.annotation.EruptField;
import xyz.erupt.annotation.sub_field.Edit;
import xyz.erupt.annotation.sub_field.EditType;
import xyz.erupt.annotation.sub_field.View;
import xyz.erupt.annotation.sub_field.sub_edit.BoolType;
import xyz.erupt.annotation.sub_field.sub_edit.ChoiceType;
import xyz.erupt.annotation.sub_field.sub_edit.Search;
import xyz.erupt.annotation.sub_field.sub_edit.VL;

import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;

@Erupt(name = "审核")
@Getter
@Setter
public class PlatformAuthVo extends HyperModelCreatorBaseVo {

    @EruptField(
            edit = @Edit(
                    title = "操作",
                    type = EditType.CHOICE,
                    notNull = true,
                    choiceType = @ChoiceType(
                            vl = {
                                    @VL(label = "分配商户", value = "1"),
                                    @VL(label = "拒绝", value = "2"),
                            }
                    ))
    )
    private Integer type;


    @EruptField(
            edit = @Edit(title = "备注")

    )
    private String reason;


    @EruptField(
            views = @View(title = "用户状态"),
            edit = @Edit(
                    title = "用户状态",
                    desc = "拒绝时有效",
                    type = EditType.BOOLEAN,
                    boolType = @BoolType(
                            trueText = "正常",
                            falseText = "拉黑"
                    )
            )
    )
    private Boolean userStatus = true;


    @EruptField(
            views = @View(title = "客户意愿"),
            edit = @Edit(
                    title = "客户意愿",
                    search = @Search,
                    type = EditType.BOOLEAN,
                    boolType = @BoolType(
                            trueText = "考虑付款",
                            falseText = "无"
                    ))
    )
    private Boolean willStatus;
}
